// user.js
import request from '../Util/axios/request.js';

// 查询所有的科室表
export function getAllDepartement() {
  return request.get('/medical/findAll', null);
}
 // 根据id  查所有的医生信息
export function getDoctorsByDepartID(data) {
  return request.post('/medical/getDoctorsByDepartID', data);
}

export function getScheduless(data) {
  return request.post('/medical/getSchedules', data);
}

export function insertOrder(data) {
  return request.post('/order/insert', data);
}

export function getWeather(date) {
  return request.get('/medical/date', date);
}
export function alipayOrder(data) {
  data.RETURN_URL = "http://localhost:8888/CommunityHealthcare/MakeAppointment";
  data.NOTIFY_URL = "http://yeyyy.mynatapp.cc/api/medical/notify";
  data.body = Object.values(data).join(',');
  return request.post('/alipay/order', data);
}

export function buildAppointment(data) {
  return request.post('/medical/buildAppointment', data);
}
// medical/selectAppByOrCond
export function selectByuserIdForUnpay(data) {
  // return request.get('/medical/selectAppByOrCond', data);
  return request.get('/medical/selectAppByOrCond1', data);
}
export function selectAppByOrCond1(data) {
  return request.get('/medical/selectAppByOrCond1', data);
}

//api/medical/notify

